﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="IframeForm.aspx.cs" Inherits="Js_Study.PlayVideo.IframeForm" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <script src="../Resource/Jquery/jquery-1.10.2.js"></script>
    <script src="/Resource/Video/PopuVideoWindow.js"></script>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <table>
                <tr>
                    <td>Name:</td>
                    <td>
                        <asp:TextBox ID="txt_name" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td>Age:</td>
                    <td>
                        <asp:TextBox ID="txt_age" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td>Address:</td>
                    <td>
                        <asp:TextBox ID="txt_address" runat="server"></asp:TextBox></td>
                </tr>
                <tr>
                    <td colspan="2">
                        <asp:Button runat="server" ID="btn_submit" Text="Submit" OnClick="btn_submit_Click" />
                        <input id="c1" type="button" value="Change Src" />
                    </td>
                </tr>
            </table>
        </div>
    </form>
</body>
</html>
<script type="text/javascript">
    $("#c1").click(function () {
        var ifr = window.parent.window.document.getElementsByTagName("IFRAME")[0];
        $(ifr).attr("src", "Video.html?link=http://enterprise.blob.core.windows.net/videos/what-office-365.mp4");
    })
</script>